package com.gitee.sunstar.skbase

import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
import androidx.databinding.DataBindingUtil
import androidx.databinding.ViewDataBinding

abstract class SKBaseActivity<DB:ViewDataBinding>: AppCompatActivity() {
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        val db : DB = DataBindingUtil.setContentView(this,setLayoutId())
        initView(db)
    }

    abstract fun initView(db: ViewDataBinding)

    abstract fun setLayoutId(): Int


}